<template>

  <el-carousel :height="searchHeight">
    <el-carousel-item v-for="item in imgs" :key="item.pic">
      <h3 class="small"><img style="height:750px;width:100%" :src="item.pic" alt=""></h3>
    </el-carousel-item>
  </el-carousel>

</template>

<script>
export default {
  props: {
    searchHeight: {
      type: Number,
      default: 0
    }
  },
  name: 'SwiPer',
  data () {
    return {
      imgs:
        [{ pic: require('@/assets/desktop_4.jpg') },
          { pic: require('@/assets/desktop_2.jpg') },
          { pic: require('@/assets/desktop_3.jpg') },
          { pic: require('@/assets/desktop_1.jpg') },
          { pic: require('@/assets/desktop_5.jpg') },
          { pic: require('@/assets/desktop_6.jpg') },
          { pic: require('@/assets/desktop_7.jpg') },
          { pic: require('@/assets/desktop_8.jpg') }
        ]
    }
  }
}
</script>

<style>
  .el-carousel__item h3 {
    color: #475669;
    font-size: 14px;
    opacity: 0.75;
    line-height: 150px;
    margin: 0;
  }

  .el-carousel__item:nth-child(2n) {
     background-color: #99a9bf;
  }

  .el-carousel__item:nth-child(2n+1) {
     background-color: #d3dce6;
  }
</style>
